fork download
  1. enum foo : unsigned char
  2. {
  3. test = 0,
  4. test2 = 0x100,
  5. };
  6.  
  7. int main() {
  8. // your code goes here
  9. return 0;
  10. }
Compilation error #stdin compilation error #stdout 0s 0KB
stdin
Standard input is empty
compilation info
prog.cpp:4:10: error: enumerator value 256 is outside the range of underlying type ‘unsigned char’
  test2 = 0x100,
          ^~~~~
stdout
Standard output is empty